import { Button, ErrorBlock, Space } from 'antd-mobile'
import { useHistory } from 'react-router'

export default function NotFound() {
  const history = useHistory()
  return (
    <div>
      <ErrorBlock title='你要访问的页面不见了' description='换个页面试试...' fullPage>
        <Space>
          <Button onClick={() => history.push('/')} color='primary'>
            返回首页
          </Button>
          <Button onClick={() => history.go(-1)} color='warning'>
            后退一步
          </Button>
        </Space>
      </ErrorBlock>
    </div>
  )
}
